| Conditions | 1 |
| Total Lines | 55 |
| Code Lines | 47 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
Small methods make your code easier to understand, in particular if combined with a good name. Besides, if your method is small, finding a good name is usually much easier.
For example, if you find yourself adding comments to a method's body, this is usually a good sign to extract the commented part to a new method, and use the comment as a starting point when coming up with a good name for this new method.
Commonly applied refactorings include:
If many parameters/temporary variables are present:
| 1 | import React, { Component } from "react" |
||
| 10 | render() { |
||
| 11 | const { affiche } = this.props.data |
||
| 12 | return ( |
||
| 13 | <Layout> |
||
| 14 | <SEO |
||
| 15 | lang="nl-BE" |
||
| 16 | title="Sinterklaas Takeaway!" |
||
| 17 | description="Sinterklaas Takeaway! - Bestelformulier" |
||
| 18 | path={this.props.location.pathname} |
||
| 19 | /> |
||
| 20 | <div className={"limited-width_wrapper"}> |
||
| 21 | <header> |
||
| 22 | <h1>Sinterklaas Takeaway</h1> |
||
| 23 | </header> |
||
| 24 | <main> |
||
| 25 | <p> |
||
| 26 | KCVV Elewijt organiseert een afhaal Sinterklaasmaaltijd op{" "} |
||
| 27 | <strong>zaterdag 5 december 2020</strong>. |
||
| 28 | </p> |
||
| 29 | |||
| 30 | <p> |
||
| 31 | Wachten op de sint zou dit jaar wel eens extra lang kunnen duren, |
||
| 32 | maak het jezelf daarom dit jaar extra aangenaam en geniet van een |
||
| 33 | heerlijk tapasbordje, pasta naar keuze en een lekker dessert, |
||
| 34 | vergezeld van een Zuid-Afrikaans wijntje terwijl de Goedheilig man |
||
| 35 | over de daken hobbelt. |
||
| 36 | </p> |
||
| 37 | <p> |
||
| 38 | <strong>Bestellen kan tot en met zondag 29 november 2020</strong>. |
||
| 39 | </p> |
||
| 40 | <p> |
||
| 41 | Opgelet: Je kan een afhaalmoment kiezen bij het bestellen. Betalen |
||
| 42 | kan ter plaatse cash of via Payconiq. |
||
| 43 | </p> |
||
| 44 | |||
| 45 | <tbkr-bm-widget |
||
| 46 | restaurant-id="34742560" |
||
| 47 | source="website" |
||
| 48 | use-modal="0" |
||
| 49 | lang="nl" |
||
| 50 | theme="light" |
||
| 51 | primary-color="#4b9b48" |
||
| 52 | takeaway="1" |
||
| 53 | ></tbkr-bm-widget> |
||
| 54 | <script src="https://reservations.tablebooker.com/tbkr-widget-import.min.js"></script> |
||
| 55 | |||
| 56 | <Img |
||
| 57 | fluid={{ |
||
| 58 | ...affiche.childImageSharp.fluid, |
||
| 59 | }} |
||
| 60 | alt="Sinterklaas Takeaway" |
||
| 61 | /> |
||
| 62 | </main> |
||
| 63 | </div> |
||
| 64 | </Layout> |
||
| 65 | ) |
||
| 78 |